import oss2

def up_to_oss(bucket_name, object_name, data):
    ak_id = 'LTAI4GBxfbsqRhK96T5gzTGD'
    ak_sct = 'eaWIvnFSFxlObDjjN4kmfZWvIuF40u'
    auth = oss2.Auth(ak_id, ak_sct)
    bucket = oss2.Bucket(auth, 'http://oss-cn-beijing.aliyuncs.com', bucket_name)
    ret = bucket.put_object(object_name, data)
    return ret
